Magnetic field sensors for detecting magnetic fields are known. In a magnetic field sensor, the magnetic field is detected by a magnetic field sensing element, such as a Hall element or a magnetoresistance element, which provides a signal (i.e., a magnetic field signal) proportional to a detected magnetic field. In some arrangements, the magnetic field signal is an electrical signal.
Magnetic field sensors are used in a variety of applications, including, but not limited to, a linear magnetic field sensor that senses a magnetic field density of a magnetic field, a current sensor that senses a magnetic field generated by a current flowing in a current carrying conductor, a magnetic switch that senses the proximity of a ferromagnetic object, and a rotation detector that senses passing ferromagnetic articles.
For a linear magnetic field sensor, the output signal changes in direct proportion to the sensed magnetic field. For a magnetic switch, the output signal changes state in response to a magnitude of the sensed magnetic field being above or below a predetermined value.
In particular, the magnetic switch uses a threshold voltage representative of a magnetic field, below which an output signal from the magnetic switch takes on a first state (e.g., a low state), and above which the output signal takes on a second different state (e.g., a high state). The threshold voltage is conventionally generated internal to the magnetic switch, and thus, is not subject to change after the magnetic switch is manufactured.
It would be desirable to have a magnetic switch for which a threshold voltage is provided in accordance with a control signal from outside the magnetic switch.